var o = "https://erjc.aexcx.cn/app";
const app=getApp();

App({
  onLaunch: function() {},
  globalData: {
      statusBarHeight: wx.getSystemInfoSync().statusBarHeight,
      screenHeight: wx.getSystemInfoSync().screenHeight,
      screenWidth: wx.getSystemInfoSync().screenWidth,
      tools: [],
      ad: {},
      host:'http://192.168.1.120:9002',
      imgUrl:'https://yake.quanxingyi.com/hightImg',
  },
  getJur: function() {
    wx.getSetting({
        success: function(e) { 
          if (!e.authSetting["scope.writePhotosAlbum"]) {
            wx.showToast({
              title: "请开启相应的权限哦！",
              icon: "none",
              duration: 1e3
            })
            return 0;
          } else {
            return 1;
          }
        }
    });
  },
  testText: function(e, i) {
    wx.request({
        url: o + "/tusi/testText.php",
        method: "POST",
        data: {
            text: e,
            id: 37
        },
        header: {
            "content-type": "application/x-www-form-urlencoded"
        },
        success: function(o) {
            return i(o);
        },
        fail: function(o) {
            console.log(o);
        }
    });
  }
})
